home *** CD-ROM | disk | FTP | other *** search
/ TeX 1995 July / TeX CD-ROM July 1995 (Disc 1)(Walnut Creek)(1995).ISO / dviware / quicspool / wwfonts / tpunct.mf < prev    next >
Text File  |  1990-10-01  |  10KB  |  242 lines

  1. % $Header: tpunct.mf,v 1.1 88/01/15 13:15:17 simpson Rel $
  2. % $Log:    tpunct.mf,v $
  3. %Revision 1.1  88/01/15  13:15:17  simpson
  4. %initial release
  5. %
  6. %Revision 0.1  87/12/11  19:01:40  simpson
  7. %beta test
  8. %
  9. % This file contains punctuation marks common to roman and italic styles.
  10.  
  11. % Codes \0041, \0043, \0045, \0047--\0054,\ %
  12. %% \0056, \0057, \0072, \0073, \0075, \0100,\par
  13. % \0133, \0135, and \0140 are generated, as well as code |spanish_shriek|
  14. % (for a Spanish exclamation point) if that code value is known.
  15.  
  16. cmchar "Exclamation point";
  17. beginchar("!",5u#+width_adj#,asc_height#,0);
  18. italcorr asc_height#*slant-2u#-.5width_adj#+.5dot_size#;
  19. adjust_fit(0,0);
  20. pickup tiny.nib; pos3(dot_size,0); pos4(dot_size,90);
  21. lft x3l=hround(.5w-.5dot_size); bot y4l=0; z3=z4; dot(3,4);  % dot
  22. numeric bot_width;
  23. bot_width=if hefty:max(hround .8dot_size,fine.breadth) else: hair fi;
  24. pickup fine.nib; pos1(dot_size,0); pos2(bot_width,0);
  25. x1=x2=x3; bot y2=.25[top y4r,x_height]+1;
  26. if square_dots: top y1=h;
  27.  filldraw stroke z1e--z2e;  % stem
  28. else: top z0=(x1,h+o); y1+.5dot_size=h+o;
  29.  filldraw z1r...z0...z1l---z2l--z2r---cycle; fi  % stem and bulb
  30. penlabels(0,1,2,3,4); endchar;
  31.  
  32. iff known spanish_shriek: cmchar "Spanish open exclamation point";
  33. beginchar(spanish_shriek,5u#+width_adj#,asc_height#-desc_depth#,desc_depth#);
  34. italcorr h#*slant-2u#-.5width_adj#+.5dot_size#;
  35. adjust_fit(0,0);
  36. pickup tiny.nib; pos3(dot_size,0); pos4(dot_size,90);
  37. lft x3l=hround(.5w-.5dot_size); top y4r=h; z3=z4; dot(3,4);  % dot
  38. numeric top_width;
  39. top_width=if hefty:max(hround .8dot_size,fine.breadth) else: hair fi;
  40. pickup fine.nib; pos1(dot_size,0); pos2(top_width,0);
  41. x1=x2=x3; top y2=.25[bot y4l,h-x_height]-1;
  42. if square_dots: bot y1=-d;
  43.  filldraw stroke z1e--z2e;  % stem
  44. else: bot z0=(x1,-d-o); y1-.5dot_size=-d-o;
  45.  filldraw z1l...z0...z1r---z2r--z2l---cycle; fi  % stem and bulb
  46. penlabels(0,1,2,3,4); endchar;
  47.  
  48. cmchar "Per cent sign";
  49. beginchar("%",9u#+max(6u#,2fudge*(hair#+stem#)),
  50.   body_height#,body_height#-asc_height#);
  51. italcorr if hefty: .4asc_height#*slant-.5u# else: h#*slant-u# fi;
  52. adjust_fit(0,0); pickup fine.nib;
  53. numeric left_curve,right_curve;
  54. left_curve=hround 5/6[fudged.hair,fudged.stem];
  55. right_curve=max(fine.breadth,hround(fudged.hair if hefty:-2stem_corr fi));
  56. pos1(vair,90); pos2(left_curve,180); pos3(vair,270); pos4(right_curve,360);
  57. top y1r=h; lft x2r=hround u; rt x4r=hround(.5w-1.5u);
  58. bot y3r=floor(if monospace: .7 else: .5 fi\\ asc_height);
  59. x1=x3=.5[x2,x4]; y2=y4=.5[y1,y3];
  60. filldraw stroke pulled_super_arc.e(1,2)(superpull)
  61.  & pulled_super_arc.e(2,3)(superpull);  % left half of upper bowl
  62. filldraw stroke super_arc.e(3,4) & super_arc.e(4,1); % right half of upper bowl
  63. pos5(vair,90); pos6(left_curve,180); pos7(vair,270); pos8(right_curve,360);
  64. bot y7r=-d; rt x8r=hround(w-u); lft x6r=hround(.5w+1.5u);
  65. top y5r=vround(if monospace: .3 else: .5 fi\\ asc_height);
  66. x5=x7=.5[x6,x8]; y6=y8=.5[y5,y7];
  67. filldraw stroke pulled_super_arc.e(5,6)(superpull)
  68.  & pulled_super_arc.e(6,7)(superpull);  % left half of lower bowl
  69. filldraw stroke super_arc.e(7,8) & super_arc.e(8,5); % right half of lower bowl
  70. pickup rule.nib; top y9=h; bot y10=-d;
  71. if hefty: x9=good.x(x5-eps); x10=good.x(x1+eps);
  72.  draw z9--z10;  % diagonal
  73. else: rt x9=hround(w-2.5u); lft x10=hround 2.5u; draw z9--z10;  % diagonal
  74.  pickup fine.nib; pos9(rule_thickness,angle(z9-z10)+90);
  75.  pos11(vair,angle(z1r-z4r)-90); pos12(vair,angle(z9-z10)+90);
  76.  path p; p=super_arc.r(1,4); z11r=point 2/3 of p; z12r=z9r;
  77.  filldraw stroke z11e{direction 2/3 of p}...{z9-z10}z12e; fi  % link
  78. penlabels(1,2,3,4,5,6,7,8,9,10,11,12); endchar;
  79.  
  80. cmchar "Apostrophe";
  81. beginchar("'",5u#,asc_height#,0);
  82. italcorr asc_height#*slant+.5dot_size#-2u#;
  83. adjust_fit(0,0);
  84. x1-.5dot_size=hround(.5w-.5dot_size); y1+.5dot_size=h;
  85. if monospace: comma(1,a,dot_size,.28u,vround 1.5comma_depth);  % large comma
  86. else: comma(1,a,dot_size,.25u,comma_depth); fi  % comma with increased jut
  87. penlabels(1); endchar;
  88.  
  89. cmchar "Left parenthesis";
  90. beginchar("(",7u# if monospace: -u# fi,body_height#,paren_depth#);
  91. italcorr body_height#*slant-.5u#;
  92. adjust_fit(0,0); pickup fine.nib;
  93. pos1(vair,0); pos2(.75[hair,stem],0); pos3(vair,0);
  94. rt x1r=rt x3r=hround(w-u); lft x2l=hround(x1-4u if monospace: +4/3u fi);
  95. top y1=h; y2=.5[y1,y3]=math_axis;
  96. filldraw stroke z1e{3(x2e-x1e),y2-y1}...z2e
  97.  ...{3(x3e-x2e),y3-y2}z3e;  % arc
  98. penlabels(1,2,3); endchar;
  99.  
  100. cmchar "Right parenthesis";
  101. beginchar(")",7u# if monospace: -u# fi,body_height#,paren_depth#);
  102. italcorr math_axis#*slant-.5u#;
  103. adjust_fit(0,0); pickup fine.nib;
  104. pos1(vair,0); pos2(.75[hair,stem],0); pos3(vair,0);
  105. lft x1l=lft x3l=hround u; rt x2r=hround(x1+4u if monospace: -4/3u fi);
  106. top y1=h; y2=.5[y1,y3]=math_axis;
  107. filldraw stroke z1e{3(x2e-x1e),y2-y1}...z2e
  108.  ...{3(x3e-x2e),y3-y2}z3e;  % arc
  109. penlabels(1,2,3); endchar;
  110.  
  111. cmchar "Asterisk";
  112. beginchar("*",9u#,
  113.   if low_asterisk:math_axis#+.5x_height# else: body_height# fi,0);
  114. italcorr h#*slant-.75u#;
  115. adjust_fit(0,0);
  116. numeric ast_flare; ast_flare=hround .7[thin_join,stem];
  117. x0=.5w; y0=h-.5x_height;
  118. for d=-150 step 60 until 150: z[d]=z0+.5dir d xscaled 7.5u yscaled x_height;
  119.  numeric theta; theta=angle(z[d]-z0);
  120.  fill z0+.5(0,-thin_join)rotated theta
  121.   ---z[d]+.5(-ast_flare,-ast_flare)rotated theta
  122.   ..z[d]..z[d]+.5(-ast_flare,ast_flare)rotated theta
  123.   ---z0+.5(0,thin_join)rotated theta--cycle; endfor  % diagonal at angle |d|
  124. labels(0,[-150],[-90],[-30],30,90,150); endchar;
  125.  
  126. cmchar "Plus sign";
  127. beginarithchar("+"); pickup rule.nib;
  128. x1=x2=good.x .5w; top y1=h+eps; .5[y1,y2]=math_axis;
  129. lft x3=hround u-eps; x4=w-x3; y3=y4=math_axis;
  130. draw z1--z2;  % stem
  131. draw z3--z4;  % crossbar
  132. labels(1,2,3,4); endchar;
  133.  
  134. cmchar "Comma";
  135. numeric dot_diam#; dot_diam#=if monospace: 5/4 fi\\ dot_size#;
  136. define_whole_blacker_pixels(dot_diam);
  137. beginchar(",",5u#,dot_diam#,comma_depth#);
  138. adjust_fit(0,0);
  139. x1-.5dot_diam=hround(.5w-.5dot_diam); y1-.5dot_diam=0;
  140. comma(1,a,dot_diam,.2u,comma_depth);  % dot and tail
  141. penlabels(1); endchar;
  142.  
  143. cmchar "Period";
  144. numeric dot_diam#; dot_diam#=if monospace: 5/4 fi\\ dot_size#;
  145. define_whole_blacker_pixels(dot_diam);
  146. beginchar(".",5u#,dot_diam#,0);
  147. adjust_fit(0,0); pickup fine.nib;
  148. pos1(dot_diam,0); pos2(dot_diam,90);
  149. lft x1l=hround(.5w-.5dot_diam); bot y2l=0; z1=z2; dot(1,2);  % dot
  150. penlabels(1,2); endchar;
  151.  
  152. cmchar "Virgule (slash)";
  153. beginchar("/",9u#,body_height#,paren_depth#);
  154. italcorr body_height#*slant-.5u#;
  155. adjust_fit(0,0); pickup rule.nib;
  156. rt x1=hround(w-u)+eps; top y1=h+eps;
  157. lft x2=hround u-eps; bot y2=-d-eps;
  158. draw z1--z2;  % diagonal
  159. penlabels(1,2); endchar;
  160.  
  161. cmchar "Colon";
  162. numeric dot_diam#; dot_diam#=if monospace: 5/4 fi\\ dot_size#;
  163. define_whole_blacker_pixels(dot_diam);
  164. beginchar(":",5u#,x_height#,0);
  165. italcorr x_height#*slant+.5dot_diam#-2u#;
  166. adjust_fit(0,0); pickup fine.nib;
  167. pos1(dot_diam,0); pos2(dot_diam,90);
  168. lft x1l=hround(.5w-.5dot_diam); top y2r=h; z1=z2; dot(1,2);  % upper dot
  169. pos3(dot_diam,0); pos4(dot_diam,90);
  170. x3=x1; bot y4l=0; z3=z4; dot(3,4);  % lower dot
  171. penlabels(1,2,3,4); endchar;
  172.  
  173. cmchar "Semicolon";
  174. numeric dot_diam#; dot_diam#=if monospace: 5/4 fi\\ dot_size#;
  175. define_whole_blacker_pixels(dot_diam);
  176. beginchar(";",5u#,x_height#,comma_depth#);
  177. italcorr x_height#*slant+.5dot_diam#-2u#;
  178. adjust_fit(0,0); pickup fine.nib;
  179. pos1(dot_diam,0); pos2(dot_diam,90);
  180. lft x1l=hround(.5w-.5dot_diam); top y2r=h; z1=z2; dot(1,2);  % upper dot
  181. x3-.5dot_diam=hround(.5w-.5dot_diam); y3-.5dot_diam=0;
  182. comma(3,a,dot_diam,.05u,comma_depth);  % lower dot and tail
  183. penlabels(1,2,3); endchar;
  184.  
  185. cmchar "Equals sign";
  186. compute_spread(.45x_height#,.55x_height#);
  187. beginchar("=",14u#,v_center(spread#+rule_thickness#));
  188. italcorr h#*slant-.5u#;
  189. adjust_fit(0,0); pickup rule.nib;
  190. lft x1=hround u-eps; x3=x1; x2=x4=w-x1;
  191. y1=y2; y3=y4; y1-y3=spread; .5[y1,y3]=math_axis;
  192. draw z1--z2;  % upper bar
  193. draw z3--z4;  % lower bar
  194. labels(1,2,3,4); endchar;
  195.  
  196. cmchar "Left bracket";
  197. numeric wd#; wd#=max(5u#,4.5u#+.5if hefty:stem# else:rule_thickness# fi);
  198. beginchar("[",wd#,body_height#,paren_depth#);
  199. italcorr body_height#*slant;
  200. adjust_fit(0,0);
  201. numeric top_thickness,side_thickness;
  202. if hefty: top_thickness=vair;
  203.  side_thickness=max(crisp.breadth,stem-2stem_corr);
  204. else: top_thickness=side_thickness=rule_thickness; fi;
  205. pickup crisp.nib; pos1(side_thickness,0); pos2(side_thickness,0);
  206. top y1=h; bot y2=-d; lft x1l=lft x2l=hround(2.5u-.5side_thickness)-1-eps;
  207. filldraw stroke z1e--z2e;  % stem
  208. pos3(top_thickness,90); pos4(top_thickness,90);
  209. pos5(top_thickness,90); pos6(top_thickness,90);
  210. x3=x5=x1l; rt x4=rt x6=ceiling(w-.4u)+eps; y3r=y4r=y1; y5l=y6l=y2;
  211. filldraw stroke z3e--z4e;  % upper bar
  212. filldraw stroke z5e--z6e;  % lower bar
  213. penlabels(1,2,3,4,5,6); endchar;
  214.  
  215. cmchar "Right bracket";
  216. numeric wd#; wd#=max(5u#,4.5u#+.5if hefty:stem# else:rule_thickness# fi);
  217. beginchar("]",wd#,body_height#,paren_depth#);
  218. italcorr body_height#*slant-2u#+.5if hefty:stem# else:rule_thickness# fi;
  219. adjust_fit(0,0);
  220. numeric top_thickness,side_thickness;
  221. if hefty: top_thickness=vair;
  222.  side_thickness=max(crisp.breadth,stem-2stem_corr);
  223. else: top_thickness=side_thickness=rule_thickness; fi;
  224. pickup crisp.nib; pos1(side_thickness,0); pos2(side_thickness,0);
  225. top y1=h; bot y2=-d; rt x1r=rt x2r=hround(w-2.5u+.5side_thickness)+1+eps;
  226. filldraw stroke z1e--z2e;  % stem
  227. pos3(top_thickness,90); pos4(top_thickness,90);
  228. pos5(top_thickness,90); pos6(top_thickness,90);
  229. x3=x5=x1r; lft x4=lft x6=floor .4u-eps; y3r=y4r=y1; y5l=y6l=y2;
  230. filldraw stroke z3e--z4e;  % upper bar
  231. filldraw stroke z5e--z6e;  % lower bar
  232. penlabels(1,2,3,4,5,6); endchar;
  233.  
  234. cmchar "Reverse apostrophe";
  235. beginchar("`",5u#,asc_height#,0);
  236. italcorr asc_height#*slant+.5dot_size#-2u#;
  237. adjust_fit(0,0);
  238. x1-.5dot_size=hround(.5w-.5dot_size); y1+.5dot_size=h-comma_depth;
  239. if monospace: ammoc(1,a,dot_size,.28u,vround 1.5comma_depth);  % large ammoc
  240. else: ammoc(1,a,dot_size,.25u,comma_depth); fi  % normal ammoc
  241. penlabels(1); endchar;
  242.